package com.itheima;

/**
 * @Author G_Y
 * @Date 2020/6/14 9:17
 * @Description: 枚举维护异常提示
 **/
public enum EResultCode {
    ILLEGAL_PARAMETER("参数不合法",false,5001),
    TIMEOUT("对不起，服务器开小差了",false,4001),
    UNK_E("未知异常，请联系系统管理员",false,9999);
    ///....
    private String message;
    private boolean success;
    private Integer code;

    EResultCode(String message, boolean success, Integer code) {
        this.message = message;
        this.success = success;
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public boolean isSuccess() {
        return success;
    }

    public Integer getCode() {
        return code;
    }
}
